package com.atguigu.order.service;

import com.atguigu.common.to.SeckillOrderTo;
import com.atguigu.order.entity.OrderEntity;
import com.atguigu.order.vo.*;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;

import java.util.Map;
import java.util.concurrent.ExecutionException;

/**
 * 订单
 *
 * @author mrs
 * @email 2314028487@qq.com
 * @date 2022-10-11 21:53:20
 */
public interface OrderService extends IService<OrderEntity> {

    PageUtils queryPage(Map<String, Object> params);

    OrderConfirmVo confirmOrder() throws ExecutionException, InterruptedException;

    SubmitOrderResponseVo submitOrder(OrderSubmitVo vo);

    void closeOrder(OrderEntity order);

    PayVo getOrderPay(String orderSn);

    PageUtils listWithItem(Map<String, Object> params);

    void handlerPayResult(PayAsyncVo payAsyncVo);

    void createSeckillOrder(SeckillOrderTo seckillOrder);
}

